package com.yjt.javatest.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.web.multipart.MultipartFile;

import javax.validation.constraints.NotNull;

@Data
@NoArgsConstructor
@AllArgsConstructor

public class Question {
  @TableId(value="question_id",type= IdType.AUTO)
  private Long questionId;
  private Long userId;
  private String image;

  @NotNull
  private Integer type;

  @NotNull
  private String content;

  @JsonIgnore
  @TableLogic
  private Boolean isDeleted;
  @NotNull
  private Integer categoryId;

  @NotNull
  private Integer score;

}
